package com.smart.tool.extension.configure;

import com.smart.tool.extension.IExtensionFinder;
import com.smart.tool.extension.impl.ExtensionFinderImpl;
import com.smart.tool.extension.processor.ExtensionProcessor;
import com.smart.tool.extension.repository.ExtensionRepositoryImpl;
import com.smart.tool.extension.repository.IExtensionRepository;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
class ExtensionConfigure {

    @Bean
    public IExtensionRepository iExtensionRepository() {
        return new ExtensionRepositoryImpl();
    }

    @Bean
    public ExtensionProcessor extensionProcessor() {
        return new ExtensionProcessor();
    }

    @Bean
    public IExtensionFinder iExtensionFinder(IExtensionRepository iExtensionRepository) {
        return new ExtensionFinderImpl(iExtensionRepository);
    }
}
